package com.block.datapush.service.apipush.utils;

import cn.hutool.core.util.StrUtil;
import com.block.common.enums.BaseTypeInfoEnum;

import javax.crypto.Cipher;
import java.nio.charset.StandardCharsets;
import java.security.KeyFactory;
import java.security.PublicKey;
import java.security.spec.X509EncodedKeySpec;
import java.util.Base64;

/**
 * 亿源互动
 */
public class YiYuanHuDong {


    public static String getloan(String loan) {
        if (StrUtil.equals(BaseTypeInfoEnum.LoanAmount.la004.getValue(), loan)) {
            return "20万";
        }  else if (StrUtil.equals(BaseTypeInfoEnum.LoanAmount.la003.getValue(), loan)) {
            return "10万";
        }
        return "5万";

    }
    public static String getzhima(String loan) {
        if (StrUtil.equals(BaseTypeInfoEnum.Zhima.zm003.getValue(), loan)) {
            return "600-649分";
        } else if (StrUtil.equals(BaseTypeInfoEnum.Zhima.zm004.getValue(), loan)) {
            return "650-699分";
        } else if (StrUtil.equals(BaseTypeInfoEnum.Zhima.zm005.getValue(), loan)) {
            return "700分以上";
        }
        return "600分以下";

    }
    public static String getgongzuo(String gongzuo) {
        if (StrUtil.equals(BaseTypeInfoEnum.Gongzuo.gz001.getValue(), gongzuo)) {
            return "上班族";
        } else if (StrUtil.equals(BaseTypeInfoEnum.Gongzuo.gz002.getValue(), gongzuo)) {
            return "私营企业主";
        }else if (StrUtil.equals(BaseTypeInfoEnum.Gongzuo.gz003.getValue(), gongzuo)) {
            return "自由职业";
        }else if (StrUtil.equals(BaseTypeInfoEnum.Gongzuo.gz004.getValue(), gongzuo)) {
            return "公务员/国企";
        }
        return "自由职业";

    }


    public static String getHouse(String house) {
        if (StrUtil.equals(BaseTypeInfoEnum.House.hu001.getValue(), house)) {
            return "无";
        }
        return "有";
    }


    public static String getCar(String car) {
        if (StrUtil.equals(BaseTypeInfoEnum.Car.car001.getValue(), car)) {
            return "无";
        }
        return "有";
    }
    public static String getxyk(String xyk) {
        if (StrUtil.equals(BaseTypeInfoEnum.XinYongKa.xyk001.getValue(), xyk)) {
            return "无";
        }
        return "30000元以上";
    }




    public static String gethuabei(String buabei) {
        if (StrUtil.equals(BaseTypeInfoEnum.Huabei.hb001.getValue(), buabei)) {
            return "无";
        }
        return "10000元以上";
    }
    public static String getbaitiao(String baitiao) {
        if (StrUtil.equals(BaseTypeInfoEnum.Baitiao.bt001.getValue(), baitiao)) {
            return "无";
        }
        return "10000元以上";
    }

    public static String getbaoxian(String baoxian) {
        if (StrUtil.equals(BaseTypeInfoEnum.Baoxian.bx001.getValue(), baoxian)) {
            return "无";
        }
        return "2年以下";
    }
    public static String getYuqi(String yuqi) {
        if (StrUtil.equals(BaseTypeInfoEnum.Yuqi.yq001.getValue(), yuqi)) {
            return "无逾期";
        }
        return "当前有逾期";
    }

    public static String getGjj(String gjj) {
        if (StrUtil.equals(BaseTypeInfoEnum.Gjj.gjj001.getValue(), gjj)) {
            return "无";
        } else if (StrUtil.equals(BaseTypeInfoEnum.Gjj.gjj002.getValue(), gjj)) {
            return "六个月以下";
        }
        return "六个月以上";
    }
    public static String getshebao(String shebao) {
        if (StrUtil.equals(BaseTypeInfoEnum.Shebao.sb001.getValue(), shebao)) {
            return "无";
        } else if (StrUtil.equals(BaseTypeInfoEnum.Shebao.sb002.getValue(), shebao)) {
            return "六个月以下";
        }
        return "六个月以上";
    }



}
